Skip to content

fix: [PR-1911] avoid recursive sf upgrade calls#246

Merged
sigmachirality merged 2 commits intomainfrom
cursor/missing-upgrade-module-fc39
Mar 18, 2026
Merged

fix: [PR-1911] avoid recursive sf upgrade calls#246
sigmachirality merged 2 commits intomainfrom
cursor/missing-upgrade-module-fc39

Conversation

@sigmachirality
Copy link
Member

Add SF_CLI_DISABLE_AUTO_UPGRADE environment variable to prevent recursive auto-upgrade checks.

The auto-upgrade process was calling sf upgrade which could trigger another auto-upgrade check, leading to recursion and process management issues. Setting this environment variable ensures that nested sf upgrade calls do not re-trigger the auto-upgrade logic.


Slack Thread

Open in Cursor Open in Web

…upgrade execution

When auto-upgrade triggered 'sf upgrade', the nested process could trigger
another auto-upgrade check, causing process management issues. Now we set
SF_CLI_DISABLE_AUTO_UPGRADE=1 when calling 'sf upgrade' and re-running the
original command to prevent this recursion.

Co-authored-by: Daniel Tao <danieltaox@gmail.com>
@cursor
Copy link

cursor bot commented Feb 6, 2026

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

@semanticdiff-com
Copy link

semanticdiff-com bot commented Feb 6, 2026

Review changes with  SemanticDiff

Changed Files
File Status
  src/lib/upgrade.ts  75% smaller
  src/checkVersion.ts  36% smaller

@sigmachirality sigmachirality changed the title Missing upgrade module fix: [PR-1911] avoid recursive sf upgrade calls Mar 18, 2026
@sigmachirality sigmachirality self-assigned this Mar 18, 2026
@sigmachirality sigmachirality marked this pull request as ready for review March 18, 2026 04:41
@sigmachirality sigmachirality merged commit 2ef578b into main Mar 18, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants